package com.mybatis;

import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface EmployeeMapperDynamicSQL {
	//携带了哪个字段，查询条件就带上这个字段的值
	List<Employee> getEmpsByConditionIf(Employee employee);

	List<Employee> getEmpsByConditionChoose(Employee employee);
	List<Employee> getEmpsByConditionForeach(@Param("ids") List<Integer> ids);

	void addEmpsByForeach(@Param("emps") List<Employee> employees);
	void updateEmps(Employee employee);

	/*使用sql片段查询*/
	List<Employee> getEmpsBySection(Integer id);
}
